package com.beehoo.dcportal.dao;

import java.util.List;

import com.beehoo.dcportal.common.base.BaseException;
import com.beehoo.dcportal.model.CommentBean;

public interface ICommentDao {
	//评论状态
	public static enum CommentStatus { 
		UNAUDITED(0), PUBLISHED(1);
		
		private int val;
		private CommentStatus(int i){
			val = i;
		}
		
		public String val(){
			return String.valueOf(val);
		}
	};
	
	/**
	 * 获取信息评论列表
	 * @param streetId
	 * @param msgId
	 * @param commentState
	 * @param iPageNo
	 * @param iRows
	 * @return
	 * @throws BaseException
	 */
	public List<CommentBean> getCommentList(String streetId, String msgId, CommentStatus commentState, int iPageNo, int iRows) throws BaseException;
	
	/**
	 * 获取信息评论总数
	 * @param streetId
	 * @param msgId
	 * @param commentState
	 * @return
	 * @throws BaseException
	 */
	public int getCommentCount(String streetId, String msgId, CommentStatus commentState) throws BaseException;
	
	/**
	 * 添加信息评论
	 * @param comment
	 * @return
	 * @throws BaseException
	 */
	public int addComment(CommentBean comment) throws BaseException;
}
